package com.xique.door.bean.domain.fenqiao;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.xique.common.core.annotation.Excel;

import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.Pattern;
import java.io.Serializable;
import java.util.Date;

/**
 * 
 * @TableName t_community
 */
@TableName(value ="t_community")
public class Community implements Serializable {
    /**
     * 主键
     */
    @TableId(type = IdType.AUTO)
    private Long id;

    /**
     * 小区名称
     */
    @Excel(name = "小区名称")
    private String communityName;

    /**
     * 社区地址
     */
    @Excel(name = "社区地址")
    private String communityAddress;

    /**
     * 社区幢
     */
    private String communityBuilding;

    /**
     * 社区单元
     */
    private String communityUnit;

    /**
     */
    private String housePlate;


    /**
     *   1-业主 2-租户
     */
    @Excel(name = "是否是业主",readConverterExp = "1=业主,2=租客")
    private Integer isOwner;

    /**
     * 物业公司
     */
    @Excel(name = "物业公司")
    private String propertyCompany;

    /**
     * 物业电话
     */
    @Excel(name = "物业电话")
    private String propertyPhone;

    /**
     * 业主姓名
     */
    @Excel(name = "姓名")
    private String ownerName;

    /**
     * 业主性别  1-男 2-女
     */
    @Excel(name = "性别")
    private Integer ownerSex;

    /**
     * 手机号码
     */
    @Excel(name = "业主性别")
    private String ownerPhone;

    /**
     * 关联索引
     */
    private Long pid;

    /**
     * 身份证
     */
    @Excel(name = "身份证")
    private String ownerCardnum;

    /*
     * 民族
     */
    @Excel(name = "民族")
    private String ownerFamous;

    /**
     * 婚姻 1-已婚  2-未婚
     */
    @Excel(name = "婚姻",readConverterExp = "1=已婚,2=未婚")
    private Integer marriage;

    /**
     * 文化程度 0-小学 1-初中  2-高中 3-中专 4-大专  5-本科  6-研究生  7-博士 8-文盲与半文盲
     */
    @Excel(name = "文化程度",readConverterExp = "0=小学,1=初中,2=高中,3=中专,4=中专,5=本科,6=研究生,7=博士,8=文盲与半文盲")
    private Integer education;

    /**
     * 党 1-是  2-不是
     */
    @Excel(name = "是否是党员",readConverterExp = "1=是,2=不是")
    private Integer isParty;

    /**
     * 工作单位
     */
    @Excel(name = "工作单位")
    private String workUnit;

    /**
     * 户籍地址
     */
    @Excel(name = "户籍地址")
    private String residenceAddress;

    /**
     * 居住地址
     */
    @Excel(name = "居住地址")
    private String lifeAddress;

    /**
     * 与业主关系
     */
    @Excel(name = "与业主关系")
    private String relationship;

    /**
     * 备注
     */
    @Excel(name = "备注")
    private String remark;

    /**
     * 创建时间
     */
    private Date ctreateTime;

    /**
     * 更新时间
     */
    private Date updateTime;

    /**
     * 1-社区住户人员   2-商户人员标识
     */
    @Excel(name = "是否是商户",readConverterExp = "1=社区人员,2=商户人员")
    private Integer type;

    @TableField(exist = false)
    private static final long serialVersionUID = 1L;

    public Community() {
    }

    public Long getId() {
        return this.id;
    }

    public String getCommunityName() {
        return this.communityName;
    }

    public String getCommunityAddress() {
        return this.communityAddress;
    }

    public String getCommunityBuilding() {
        return this.communityBuilding;
    }

    public String getCommunityUnit() {
        return this.communityUnit;
    }

    public String getHousePlate() {
        return this.housePlate;
    }

    public Integer getIsOwner() {
        return this.isOwner;
    }

    public String getPropertyCompany() {
        return this.propertyCompany;
    }

    public String getPropertyPhone() {
        return this.propertyPhone;
    }

    public String getOwnerName() {
        return this.ownerName;
    }

    public Integer getOwnerSex() {
        return this.ownerSex;
    }

    public String getOwnerPhone() {
        return this.ownerPhone;
    }

    public Long getPid() {
        return this.pid;
    }

    public @NotEmpty(message = "身份证号不能为空") String getOwnerCardnum() {
        return this.ownerCardnum;
    }

    public String getOwnerFamous() {
        return this.ownerFamous;
    }

    public Integer getMarriage() {
        return this.marriage;
    }

    public Integer getEducation() {
        return this.education;
    }

    public Integer getIsParty() {
        return this.isParty;
    }

    public String getWorkUnit() {
        return this.workUnit;
    }

    public String getResidenceAddress() {
        return this.residenceAddress;
    }

    public String getLifeAddress() {
        return this.lifeAddress;
    }

    public String getRelationship() {
        return this.relationship;
    }

    public String getRemark() {
        return this.remark;
    }

    public Date getCtreateTime() {
        return this.ctreateTime;
    }

    public Date getUpdateTime() {
        return this.updateTime;
    }

    public Integer getType() {
        return this.type;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public void setCommunityName(String communityName) {
        this.communityName = communityName;
    }

    public void setCommunityAddress(String communityAddress) {
        this.communityAddress = communityAddress;
    }

    public void setCommunityBuilding(String communityBuilding) {
        this.communityBuilding = communityBuilding;
    }

    public void setCommunityUnit(String communityUnit) {
        this.communityUnit = communityUnit;
    }

    public void setHousePlate(String housePlate) {
        this.housePlate = housePlate;
    }

    public void setIsOwner(Integer isOwner) {
        this.isOwner = isOwner;
    }

    public void setPropertyCompany(String propertyCompany) {
        this.propertyCompany = propertyCompany;
    }

    public void setPropertyPhone(String propertyPhone) {
        this.propertyPhone = propertyPhone;
    }

    public void setOwnerName(String ownerName) {
        this.ownerName = ownerName;
    }

    public void setOwnerSex(Integer ownerSex) {
        this.ownerSex = ownerSex;
    }

    public void setOwnerPhone(String ownerPhone) {
        this.ownerPhone = ownerPhone;
    }

    public void setPid(Long pid) {
        this.pid = pid;
    }

    public void setOwnerCardnum(@NotEmpty(message = "身份证号不能为空") String ownerCardnum) {
        this.ownerCardnum = ownerCardnum;
    }

    public void setOwnerFamous(String ownerFamous) {
        this.ownerFamous = ownerFamous;
    }

    public void setMarriage(Integer marriage) {
        this.marriage = marriage;
    }

    public void setEducation(Integer education) {
        this.education = education;
    }

    public void setIsParty(Integer isParty) {
        this.isParty = isParty;
    }

    public void setWorkUnit(String workUnit) {
        this.workUnit = workUnit;
    }

    public void setResidenceAddress(String residenceAddress) {
        this.residenceAddress = residenceAddress;
    }

    public void setLifeAddress(String lifeAddress) {
        this.lifeAddress = lifeAddress;
    }

    public void setRelationship(String relationship) {
        this.relationship = relationship;
    }

    public void setRemark(String remark) {
        this.remark = remark;
    }

    public void setCtreateTime(Date ctreateTime) {
        this.ctreateTime = ctreateTime;
    }

    public void setUpdateTime(Date updateTime) {
        this.updateTime = updateTime;
    }

    public void setType(Integer type) {
        this.type = type;
    }

    public boolean equals(final Object o) {
        if (o == this) return true;
        if (!(o instanceof Community)) return false;
        final Community other = (Community) o;
        if (!other.canEqual((Object) this)) return false;
        final Object this$id = this.getId();
        final Object other$id = other.getId();
        if (this$id == null ? other$id != null : !this$id.equals(other$id)) return false;
        final Object this$communityName = this.getCommunityName();
        final Object other$communityName = other.getCommunityName();
        if (this$communityName == null ? other$communityName != null : !this$communityName.equals(other$communityName))
            return false;
        final Object this$communityAddress = this.getCommunityAddress();
        final Object other$communityAddress = other.getCommunityAddress();
        if (this$communityAddress == null ? other$communityAddress != null : !this$communityAddress.equals(other$communityAddress))
            return false;
        final Object this$communityBuilding = this.getCommunityBuilding();
        final Object other$communityBuilding = other.getCommunityBuilding();
        if (this$communityBuilding == null ? other$communityBuilding != null : !this$communityBuilding.equals(other$communityBuilding))
            return false;
        final Object this$communityUnit = this.getCommunityUnit();
        final Object other$communityUnit = other.getCommunityUnit();
        if (this$communityUnit == null ? other$communityUnit != null : !this$communityUnit.equals(other$communityUnit))
            return false;
        final Object this$housePlate = this.getHousePlate();
        final Object other$housePlate = other.getHousePlate();
        if (this$housePlate == null ? other$housePlate != null : !this$housePlate.equals(other$housePlate))
            return false;
        final Object this$isOwner = this.getIsOwner();
        final Object other$isOwner = other.getIsOwner();
        if (this$isOwner == null ? other$isOwner != null : !this$isOwner.equals(other$isOwner)) return false;
        final Object this$propertyCompany = this.getPropertyCompany();
        final Object other$propertyCompany = other.getPropertyCompany();
        if (this$propertyCompany == null ? other$propertyCompany != null : !this$propertyCompany.equals(other$propertyCompany))
            return false;
        final Object this$propertyPhone = this.getPropertyPhone();
        final Object other$propertyPhone = other.getPropertyPhone();
        if (this$propertyPhone == null ? other$propertyPhone != null : !this$propertyPhone.equals(other$propertyPhone))
            return false;
        final Object this$ownerName = this.getOwnerName();
        final Object other$ownerName = other.getOwnerName();
        if (this$ownerName == null ? other$ownerName != null : !this$ownerName.equals(other$ownerName)) return false;
        final Object this$ownerSex = this.getOwnerSex();
        final Object other$ownerSex = other.getOwnerSex();
        if (this$ownerSex == null ? other$ownerSex != null : !this$ownerSex.equals(other$ownerSex)) return false;
        final Object this$ownerPhone = this.getOwnerPhone();
        final Object other$ownerPhone = other.getOwnerPhone();
        if (this$ownerPhone == null ? other$ownerPhone != null : !this$ownerPhone.equals(other$ownerPhone))
            return false;
        final Object this$pid = this.getPid();
        final Object other$pid = other.getPid();
        if (this$pid == null ? other$pid != null : !this$pid.equals(other$pid)) return false;
        final Object this$ownerCardnum = this.getOwnerCardnum();
        final Object other$ownerCardnum = other.getOwnerCardnum();
        if (this$ownerCardnum == null ? other$ownerCardnum != null : !this$ownerCardnum.equals(other$ownerCardnum))
            return false;
        final Object this$ownerFamous = this.getOwnerFamous();
        final Object other$ownerFamous = other.getOwnerFamous();
        if (this$ownerFamous == null ? other$ownerFamous != null : !this$ownerFamous.equals(other$ownerFamous))
            return false;
        final Object this$marriage = this.getMarriage();
        final Object other$marriage = other.getMarriage();
        if (this$marriage == null ? other$marriage != null : !this$marriage.equals(other$marriage)) return false;
        final Object this$education = this.getEducation();
        final Object other$education = other.getEducation();
        if (this$education == null ? other$education != null : !this$education.equals(other$education)) return false;
        final Object this$isParty = this.getIsParty();
        final Object other$isParty = other.getIsParty();
        if (this$isParty == null ? other$isParty != null : !this$isParty.equals(other$isParty)) return false;
        final Object this$workUnit = this.getWorkUnit();
        final Object other$workUnit = other.getWorkUnit();
        if (this$workUnit == null ? other$workUnit != null : !this$workUnit.equals(other$workUnit)) return false;
        final Object this$residenceAddress = this.getResidenceAddress();
        final Object other$residenceAddress = other.getResidenceAddress();
        if (this$residenceAddress == null ? other$residenceAddress != null : !this$residenceAddress.equals(other$residenceAddress))
            return false;
        final Object this$lifeAddress = this.getLifeAddress();
        final Object other$lifeAddress = other.getLifeAddress();
        if (this$lifeAddress == null ? other$lifeAddress != null : !this$lifeAddress.equals(other$lifeAddress))
            return false;
        final Object this$relationship = this.getRelationship();
        final Object other$relationship = other.getRelationship();
        if (this$relationship == null ? other$relationship != null : !this$relationship.equals(other$relationship))
            return false;
        final Object this$remark = this.getRemark();
        final Object other$remark = other.getRemark();
        if (this$remark == null ? other$remark != null : !this$remark.equals(other$remark)) return false;
        final Object this$ctreateTime = this.getCtreateTime();
        final Object other$ctreateTime = other.getCtreateTime();
        if (this$ctreateTime == null ? other$ctreateTime != null : !this$ctreateTime.equals(other$ctreateTime))
            return false;
        final Object this$updateTime = this.getUpdateTime();
        final Object other$updateTime = other.getUpdateTime();
        if (this$updateTime == null ? other$updateTime != null : !this$updateTime.equals(other$updateTime))
            return false;
        final Object this$type = this.getType();
        final Object other$type = other.getType();
        if (this$type == null ? other$type != null : !this$type.equals(other$type)) return false;
        return true;
    }

    protected boolean canEqual(final Object other) {
        return other instanceof Community;
    }

    public int hashCode() {
        final int PRIME = 59;
        int result = 1;
        final Object $id = this.getId();
        result = result * PRIME + ($id == null ? 43 : $id.hashCode());
        final Object $communityName = this.getCommunityName();
        result = result * PRIME + ($communityName == null ? 43 : $communityName.hashCode());
        final Object $communityAddress = this.getCommunityAddress();
        result = result * PRIME + ($communityAddress == null ? 43 : $communityAddress.hashCode());
        final Object $communityBuilding = this.getCommunityBuilding();
        result = result * PRIME + ($communityBuilding == null ? 43 : $communityBuilding.hashCode());
        final Object $communityUnit = this.getCommunityUnit();
        result = result * PRIME + ($communityUnit == null ? 43 : $communityUnit.hashCode());
        final Object $housePlate = this.getHousePlate();
        result = result * PRIME + ($housePlate == null ? 43 : $housePlate.hashCode());
        final Object $isOwner = this.getIsOwner();
        result = result * PRIME + ($isOwner == null ? 43 : $isOwner.hashCode());
        final Object $propertyCompany = this.getPropertyCompany();
        result = result * PRIME + ($propertyCompany == null ? 43 : $propertyCompany.hashCode());
        final Object $propertyPhone = this.getPropertyPhone();
        result = result * PRIME + ($propertyPhone == null ? 43 : $propertyPhone.hashCode());
        final Object $ownerName = this.getOwnerName();
        result = result * PRIME + ($ownerName == null ? 43 : $ownerName.hashCode());
        final Object $ownerSex = this.getOwnerSex();
        result = result * PRIME + ($ownerSex == null ? 43 : $ownerSex.hashCode());
        final Object $ownerPhone = this.getOwnerPhone();
        result = result * PRIME + ($ownerPhone == null ? 43 : $ownerPhone.hashCode());
        final Object $pid = this.getPid();
        result = result * PRIME + ($pid == null ? 43 : $pid.hashCode());
        final Object $ownerCardnum = this.getOwnerCardnum();
        result = result * PRIME + ($ownerCardnum == null ? 43 : $ownerCardnum.hashCode());
        final Object $ownerFamous = this.getOwnerFamous();
        result = result * PRIME + ($ownerFamous == null ? 43 : $ownerFamous.hashCode());
        final Object $marriage = this.getMarriage();
        result = result * PRIME + ($marriage == null ? 43 : $marriage.hashCode());
        final Object $education = this.getEducation();
        result = result * PRIME + ($education == null ? 43 : $education.hashCode());
        final Object $isParty = this.getIsParty();
        result = result * PRIME + ($isParty == null ? 43 : $isParty.hashCode());
        final Object $workUnit = this.getWorkUnit();
        result = result * PRIME + ($workUnit == null ? 43 : $workUnit.hashCode());
        final Object $residenceAddress = this.getResidenceAddress();
        result = result * PRIME + ($residenceAddress == null ? 43 : $residenceAddress.hashCode());
        final Object $lifeAddress = this.getLifeAddress();
        result = result * PRIME + ($lifeAddress == null ? 43 : $lifeAddress.hashCode());
        final Object $relationship = this.getRelationship();
        result = result * PRIME + ($relationship == null ? 43 : $relationship.hashCode());
        final Object $remark = this.getRemark();
        result = result * PRIME + ($remark == null ? 43 : $remark.hashCode());
        final Object $ctreateTime = this.getCtreateTime();
        result = result * PRIME + ($ctreateTime == null ? 43 : $ctreateTime.hashCode());
        final Object $updateTime = this.getUpdateTime();
        result = result * PRIME + ($updateTime == null ? 43 : $updateTime.hashCode());
        final Object $type = this.getType();
        result = result * PRIME + ($type == null ? 43 : $type.hashCode());
        return result;
    }

    public String toString() {
        return "Community(id=" + this.getId() + ", communityName=" + this.getCommunityName() + ", communityAddress=" + this.getCommunityAddress() + ", communityBuilding=" + this.getCommunityBuilding() + ", communityUnit=" + this.getCommunityUnit() + ", housePlate=" + this.getHousePlate() + ", isOwner=" + this.getIsOwner() + ", propertyCompany=" + this.getPropertyCompany() + ", propertyPhone=" + this.getPropertyPhone() + ", ownerName=" + this.getOwnerName() + ", ownerSex=" + this.getOwnerSex() + ", ownerPhone=" + this.getOwnerPhone() + ", pid=" + this.getPid() + ", ownerCardnum=" + this.getOwnerCardnum() + ", ownerFamous=" + this.getOwnerFamous() + ", marriage=" + this.getMarriage() + ", education=" + this.getEducation() + ", isParty=" + this.getIsParty() + ", workUnit=" + this.getWorkUnit() + ", residenceAddress=" + this.getResidenceAddress() + ", lifeAddress=" + this.getLifeAddress() + ", relationship=" + this.getRelationship() + ", remark=" + this.getRemark() + ", ctreateTime=" + this.getCtreateTime() + ", updateTime=" + this.getUpdateTime() + ", type=" + this.getType() + ")";
    }
}